<!--navbar的使用  -->
<template>
  <div class="navbar-main">
    <van-nav-bar :title='title' left-text="返回" left-arrow @click-left="goBack" />
  </div>
</template>

<script>
import Vue from "vue";
import { NavBar } from "vant";

Vue.use(NavBar);
export default {
  props:['title'],
  data() {
    return {};
  },
  created() {},
  methods: {
    goBack() {
      this.$router.go(-1);
    },
  },
};
</script>
<style lang='scss' scoped>
.navbar-main {
  ::v-deep .van-nav-bar__title,
  ::v-deep .van-nav-bar .van-icon,
  ::v-deep .van-nav-bar__text {
    color: $baseColor !important;
  }
}
</style>